Electronic apparatus and control method thereof

ABSTRACT

An electronic apparatus is provided. The electronic apparatus includes a sensor, a first light source configured to irradiate a first light, a second light source configured to irradiate a second light in a direction different from the first light, and a processor configured to, based on first and second reflected lights being received by the sensor as the first and second lights are reflected by an object, calculate a first distance between the electronic apparatus and an object reflecting the first light and a second distance between the electronic apparatus and an object reflecting the second light using different calculation methods.

CROSS-REFERENCE TO RELATED APPLICATION(S)

This application is based on and claims priority under 35 U.S.C. §119(a) of a Korean patent application number 10-2019-0141199, filed onNov. 6, 2019, in the Korean Intellectual Property Office, the disclosureof which is incorporated by reference herein in its entirety.

BACKGROUND 1. Field

The disclosure relates to an electronic apparatus and a method forcontrolling thereof. More particularly, the disclosure relates to anelectronic apparatus capable of sensing an object around the electronicapparatus and a method for controlling thereof.

2. Description of Related Art

The development of electronic technology has led to the development of avariety of electronic apparatuses. In particular, there has recentlybeen developed an electronic apparatus, such as an automated drivingvehicle that performs driving on behalf of a human, an automated guidedvehicle that classifies goods by itself, and carries the goods to adestination, and a robot cleaner that performs cleaning while drivingthe indoor space within a house by itself.

To prevent a collision with an object during driving, this kind ofelectronic apparatus needs to sense various objects located around theelectronic apparatus. For this purpose, an electronic apparatus having asensor (e.g., an image sensor or a light detection and ranging (LiDAR)sensor or the like) capable of sensing an object around an electronicapparatus using a plurality of light sources has been developed.

A related-art electronic apparatus having a plurality of lightsource-based sensors emits a plurality of light through a plurality oflight sources, and when a plurality of reflected light is received inthe sensor, it is recognized that different objects exist at differentpositions. However, the plurality of reflected light may be lightreflected from one object, rather than light reflected from differentobjects. In the latter case, the related-art electronic apparatus has aproblem of recognizing as if a plurality of objects are present, eventhough only one object is actually present around the electronicapparatus.

The above information is presented as background information only toassist with an understanding of the disclosure. No determination hasbeen made, and no assertion is made, as to whether any of the abovemight be applicable as prior art with regard to the disclosure.

SUMMARY

Aspects of the disclosure are to address at least the above-mentionedproblems and/or disadvantages and to provide at least the advantagesdescribed below. Accordingly, an aspect of the disclosure is to providea user with an electronic apparatus including a sensor, a first lightsource configured to irradiate a first light, a second light sourceconfigured to irradiate a second light in a direction different from thefirst light, and a processor configured to, based on first and secondreflected lights being received by the sensor as the first and secondlights are reflected by an object, calculate a first distance betweenthe electronic apparatus and an object reflecting the first light and asecond distance between the electronic apparatus and an objectreflecting the second light using different calculation methods.

Additional aspects will be set forth in part in the description whichfollows and, in part, will be apparent from the description, or may belearned by practice of the presented embodiments.

In accordance with an aspect of the disclosure, a method for controllingan electronic apparatus is provided. The method includes irradiating afirst light through a first light source and irradiating a second lightin a direction different from the first light through a second lightsource, and, based on first and second reflected lights being receivedby the sensor as the first and second lights are reflected by an object,calculating a first distance between the electronic apparatus and anobject reflecting the first light and a second distance between theelectronic apparatus and an object reflecting the second light usingdifferent calculation methods.

In accordance with another aspect of the disclosure, a sensor isprovided. The sensor includes a plurality of pixels, a first lightsource configured to irradiate a first light, a second light sourceconfigured to irradiate a second light in a direction different from thefirst light, and a processor configured to, based on receiving the firstand second reflected lights at the plurality of pixels as the first andsecond lights are reflected by an object, calculate a first distancebetween an electronic apparatus and an object reflecting the first lightand a second distance between the electronic apparatus and an objectreflecting the second light using different calculation methods.

Other aspects, advantages, and salient features of the disclosure willbecome apparent to those skilled in the art from the following detaileddescription, which, taken in conjunction with the annexed drawings,discloses various embodiments of the disclosure.

BRIEF DESCRIPTION OF THE DRAWINGS

The above and other aspects, features, and advantages of certainembodiments of the disclosure will be more apparent from the followingdescription taken in conjunction with the accompanying drawings, inwhich:

FIG. 1A is a diagram illustrating an electronic apparatus according toan embodiment of the disclosure;

FIG. 1B is a diagram illustrating a sensor according to an embodiment ofthe disclosure;

FIG. 1C is a diagram illustrating a sensor receiving a plurality ofreflected lights according to an embodiment of the disclosure;

FIG. 2 is a block diagram illustrating an electronic apparatus accordingto an embodiment of the disclosure;

FIG. 3 is a diagram illustrating a sensor according to an embodiment ofthe disclosure;

FIG. 4A is a diagram illustrating a case where reflected light isreceived by light of a first light source according to an embodiment ofthe disclosure;

FIG. 4B is a diagram illustrating a sensor receiving reflected light bylight of a first light source according to an embodiment of thedisclosure;

FIG. 4C is a diagram illustrating a method for calculating a distancebetween an electronic apparatus and an object based on the reflectedlight by light of the first light source according to an embodiment ofthe disclosure;

FIG. 5A is a diagram illustrating that reflected light is received bylight of a second light source according to an embodiment of thedisclosure;

FIG. 5B is a diagram illustrating a sensor receiving reflected light bylight of a second light source according to an embodiment of thedisclosure;

FIG. 5C is a diagram illustrating a method for calculating a distancebetween an electronic apparatus and an object based on reflected lightby light of the second light source according to an embodiment of thedisclosure;

FIG. 6A is a diagram illustrating a sensor receiving a plurality ofreflected lights in a second region according to an embodiment of thedisclosure;

FIG. 6B is a diagram illustrating that a plurality of objects arepositioned at a region capable of sensing an object by the second lightsource according to an embodiment of the disclosure;

FIG. 6C is a diagram illustrating that an object is positioned in aregion capable of sensing an object by the second light source accordingto an embodiment of the disclosure;

FIG. 7 is a block diagram illustrating a sensor according to anembodiment of the disclosure;

FIG. 8A is a diagram illustrating an embodiment of irradiating light ofdifferent patterns by a plurality of light sources according to anembodiment of the disclosure;

FIG. 8B is a diagram illustrating a sensor receiving a plurality oflights of different patterns according to an embodiment of thedisclosure;

FIG. 9A is a diagram illustrating an embodiment of irradiating light ofthickness by a plurality of light sources according to an embodiment ofthe disclosure;

FIG. 9B is a diagram illustrating a sensor receiving a plurality oflights having different thickness according to an embodiment of thedisclosure;

FIG. 10 is a diagram illustrating an embodiment of identifying reflectedlight by first light source and reflected light by second light sourceusing information on a thickness of reflected light according to anembodiment of the disclosure;

FIG. 11 is a diagram illustrating an embodiment of identifying reflectedlight by the first light source and reflected light by the second lightsource based on a cycle according to an embodiment of the disclosure;

FIG. 12 is a flowchart illustrating a method for controlling anelectronic apparatus according to an embodiment of the disclosure;

FIG. 13 is a flowchart illustrating a method for controlling a sensoraccording to an embodiment of the disclosure; and

FIG. 14 is a detailed block diagram illustrating an electronic apparatusaccording to an embodiment of the disclosure.

The same reference numerals are used to represent the same elementsthroughout the drawings.

DETAILED DESCRIPTION

The following description with reference to the accompanying drawings isprovided to assist in a comprehensive understanding of variousembodiments of the disclosure as defined by the claims and theirequivalents. It includes various specific details to assist in thatunderstanding, but these are to be regarded as merely exemplary.Accordingly, those of ordinary skill in the art will recognize thatvarious changes and modifications of the various embodiments describedherein can be made without departing from the scope and spirit of thedisclosure. In addition, descriptions of well-known functions andconstructions may be omitted for clarity and conciseness.

The terms and words used in the following description and claims are notlimited to the bibliographical meanings, but are merely used by theinventor to enable a clear and consistent understanding of thedisclosure. Accordingly, it should be apparent to those skilled in theart that the following description of various embodiments of thedisclosure is provided for illustration purposes only and not for thepurpose of limiting the disclosure as defined by the appended claims andtheir equivalents.

It is to be understood that the singular forms “a,” “an,” and “the”include plural referents unless the context clearly dictates otherwise.Thus, for example, reference to “a component surface” includes referenceto one or more of such surfaces.

When it is decided that a detailed description for the known art relatedto the disclosure may unnecessarily obscure the gist of the disclosure,the detailed description of the known art may be shortened or omitted.

Various example embodiments will be described in greater detail belowwith reference to the attached drawings, but it will be understood thatthe disclosure is not limited by the various example embodimentsdescribed herein.

Hereinafter, the embodiment will be described in greater detail belowwith reference to the drawings.

The disclosure provides an electronic apparatus capable of identifyingwhether a plurality of reflected lights received at a sensor are lightsreflected by one object or by a plurality of objects and a method forcontrolling thereof.

FIG. 1A is a diagram illustrating an electronic apparatus according toan embodiment of the disclosure.

FIG. 1B is a diagram illustrating a sensor according to an embodiment ofthe disclosure.

Referring to FIGS. 1A and 1B, electronic apparatus 100 according to anembodiment of the disclosure may be a movable electronic apparatus. Asan example, the electronic apparatus 100 may be an automated drivingvehicle that performs driving on behalf of a person, an automated guidedvehicle capable of moving goods to a destination, or a robot cleanercapable of performing a cleaning operation while driving a space in ahouse. However, the embodiment is not limited thereto and the electronicapparatus 100 may be implemented with a variety of electronicapparatuses, such as a robot capable of performing an air cleaningoperation while driving in a space of a building, a housework supporttype robot capable of performing a work such as a clothes arrangement,dish-washing, and the like, while driving in a space of a house, or aguard robot capable of performing a guard work while driving in a spaceof a building, or the like.

The electronic apparatus 100 may irradiate a plurality of light througha plurality of light sources. The light irradiated by each light sourcemay be, for example, a fan-shaped planar light, but the embodiment isnot limited thereto and may be in various forms.

Referring to FIG. 1A, the electronic apparatus 100 may irradiate a firstlight 111 through a first light source 110 and irradiate a second light121 through a second light source 120. The first light source 110 mayirradiate the first light 111 in a front direction of the electronicapparatus 100, and the second light source 120 may irradiate the secondlight 121 in a downward direction by a predetermined angle from thefront direction of the electronic apparatus 100. In one example, thesecond light source 120 may irradiate the second light in the downwarddirection by 30 degrees from the front direction.

The second light source 120 may be located at a lower portion of thefirst light source 110 as illustrated in FIG. 1A. The first light source110 and the second light source 120 may be disposed at a left side or aright side at the same height.

Two light sources are illustrated in FIG. 1A, but this is only oneembodiment and the number of light sources is not so limited. Theelectronic apparatus 100 may include three or more light sources. Theelectronic apparatus 100 may also include one light source. In thisexample, the electronic apparatus 100 may irradiate two or more lightsthrough a splitter included in the light source. In one example, whenthe light irradiated by the splitter is two, the first light of the twolights may be irradiated in the front direction of the electronicapparatus 100, and the second light may be irradiated in the downwarddirection from the front direction of the electronic apparatus 100 by apredetermined angle.

For convenience of description, it is assumed that the electronicapparatus 100 includes two light sources.

When the first light 111 irradiated by the first light source 110 andthe second light 121 irradiated by the second light source 120 arereflected by an object, a sensor 130 of the electronic apparatus 100 mayreceive the first reflected light and the second reflected light. Thefirst reflected light may be light reflected by the object and thesecond reflected light may be light reflected by the object. Forexample, referring to FIG. 1A, the sensor 130 may receive the firstreflected light 112 when the first light 111 is reflected by the firstobject 10, and may receive the second reflected light 122 when thesecond light 121 is reflected by the second object 20. For convenienceof description, referring to FIG. 1A, the light irradiated by the lightsource is illustrated in a solid line form and the reflected lightreflected by the object is illustrated in a dotted line, but the shapeof the reflected light depends on the type of light.

The sensor 130 may be implemented as an image sensor including aplurality of pixels.

Referring to FIG. 1B, the sensor 130 may be implemented with an imagesensor that includes a plurality of pixels. The plurality of pixels maybe arranged in a matrix form, and the ratio of the width to height ofthe plurality of pixels may be 2:1, as illustrated in FIG. 1B, but isnot necessarily limited thereto.

FIG. 1C is a diagram illustrating a sensor receiving a plurality ofreflected lights according to an embodiment of the disclosure.

Referring to FIG. 1A, when the first light 111 is reflected by the firstobject 10 and the second light 121 is reflected by the second object 20,the sensor 130 may receive the first reflected light 121 and the secondreflected light 122, as shown in FIG. 1C. In this example, theelectronic apparatus 100 may calculate a distance from the first lightsource 110 to the first object 10 based on the position of the pixelswhich receive the first reflected light 121, among the plurality ofpixels included in the sensor 130, and may calculate a distance from thesecond light source 120 to the second object 20 based on the position ofthe pixels which receive the second reflected light 122. This will bedescribed in detail with reference to FIG. 2.

FIG. 2 is a block diagram illustrating an electronic apparatus accordingto an embodiment of the disclosure.

FIG. 3 is a diagram illustrating a sensor according to an embodiment ofthe disclosure.

Referring to FIG. 2, the electronic apparatus 100 includes the firstlight source 110, the second light source 120, the sensor 130, and aprocessor 140.

The first light source 110 may irradiate the first light 111. The firstlight source 110 may irradiate the first light in the front direction ofthe electronic apparatus 100. The processor 140 may identify an objectlocated remotely from the electronic apparatus 100 and/or an objectlocated nearby based on the first reflected light of the first light.

The second light source 120 may irradiate the second light in adirection different from the first light. The first light source 110 mayirradiate the first light in the front direction of the electronicapparatus 100, and the second light source 120 may irradiate the secondlight in the downward direction by a predetermined angle from the frontdirection of the electronic apparatus 100. In one example, the secondlight source 120 may irradiate the second light in the downwarddirection by 30 degrees from the front direction, but is not necessarilylimited thereto. As will be described below, the processor 140 mayidentify an object that is located at a near distance from theelectronic apparatus 100 based on the second reflected light of thesecond light.

The first light source 110 and the second light source 120 may beimplemented as various light sources that may irradiate light such aslaser diode, line laser, or the like.

The sensor 130 may be located at an upper portion of the first lightsource 110. The sensor 130 may receive reflected light of the lightirradiated toward the object. The sensor 130 may receive the firstreflected light when the first light irradiated by the first lightsource 110 is reflected by the object, and may receive the secondreflected light when the second light irradiated by the second lightsource 120 is reflected by the object.

The sensor 130 may be implemented as an image sensor that includes aplurality of pixels arranged in a matrix form, as described above. Theplurality of pixels may be arranged in a form of M×M or M×N where M andN are integers. For example, referring to FIG. 3, the sensor 130 may becomposed of 200 pixels, and 200 pixels may be arranged in ten rows andtwenty columns, but are not necessarily limited thereto. However, forconvenience of description, the sensor 130 is assumed to be arranged inten rows and twenty columns, as illustrated in FIG. 3.

When the reflected light is received from the sensor 130, the sensor 130may sense a pixel that has received the reflected light among theplurality of pixels. Specifically, the sensor 130 may sense a pixelhaving a brightness greater than or equal to a predetermined brightnessvalue among the plurality of pixels as a pixel that has received thereflected light. The predetermined brightness value may be variously setaccording to the brightness value of the light irradiated by the lightsource.

Referring to FIG. 3, a plurality of pixels included in the sensor 130may be divided into pixels of a first region and pixels in a secondregion. The first region is a region for calculating a distance from theelectronic apparatus 100 to an object located at a distance from theelectronic apparatus 100, and the second region may be a region forcalculating a distance from the electronic apparatus 100 to an objectlocated at a near distance from the electronic apparatus 100.

A plurality of pixels may be divided into pixels in a first region andpixels in a second region based on pixels of a predetermined row. Forexample, if the predetermined row is a row 3, the pixels included in alower row of row 3 including row 3 may be divided into pixels of thefirst region, and the pixels included in the upper row of row 3 (i.e.,rows 4 to row 10) may be divided into pixels in the second region.

The predetermined row may be determined based on a location wherereflected light by the light of the second light source 120 may bereceived at the sensor 130. For example, if the reflected light by thelight of the second light source 120 may only be received in pixelsincluded in rows 1 to 3 among the plurality of pixels included in thesensor 130, the predetermined row may be row 3. The position in whichthe reflected light by the light of the second light source 120 may bereceived in the sensor 130 may be different according to the embodimentbased on the illumination angle of the second light source 120, theangle at which the sensor 130 is inclined in the ground direction, orthe like.

The processor 140 may control overall operations of the electronicapparatus 100. The processor 140 may include, for example, and withoutlimitation, one or more of a central processing unit (CPU), anapplication processor (AP), a communication processor (CP), or the like.The processor 140 may be implemented as at least one of a generalprocessor, a digital signal processor, an application specificintegrated circuit (ASIC), a system on chip (SoC), a microcomputer(MICOM), or the like.

The processor 140 may control the first light source 110 to irradiatethe first light and control the second light source 120 to irradiate thesecond light. In this example, when the first light irradiated by thefirst light source 110 is reflected by the object, the sensor 130 mayreceive the first reflected light, and if the second light irradiated bythe second light source 120 is reflected by the object, the sensor 130may receive the second reflected light.

The processor 140 may receive information from the sensor 130 regardingthe location of the pixels that received the first reflected light andthe locations of the pixels that received the second reflected lightfrom among the plurality of pixels included in the sensor 130. When thefirst and second reflected lights are received, the sensor 130 may sensethe brightness of a plurality of pixels included in the sensor 130. Thesensor 130 may sense pixels having a brightness greater than or equal toa predetermined brightness value among the plurality of pixels as pixelsreceiving the first reflected light and pixels receiving the secondreflected light, and may transmit information regarding the position ofthe pixels receiving the first reflected light and the position of thepixels receiving the second reflected light to the processor 140. Forexample, as shown in FIG. 3, when first reflected light 112 is receivedat columns 8-12 of row 7, and second reflected light 122 is received incolumns 8-12 of row 2, the sensor 130 may transmit, to the processor140, information that first reflected light 112 is received to columns8-12 of row 7 and information that second reflected light 122 isreceived in columns 8-12 of row 2.

The processor 140 may determine (or identify) whether the position ofthe pixels that received the first reflected light 112 is included inthe first region or in the second region. The processor 140 maydetermine whether the position of the pixels that received the secondreflected light 122 is included in the first region or in the secondregion. In one example, when the processor 140 receives information fromthe sensor 130 that the first reflected light 112 has been received fromthe sensor 130 in the columns 8-12 of row 7, since the row whichreceived the first reflected light 112 is low 7 that is upper portionthan low 3 which is a predetermined low row and thus, it is determinedthat the first reflected light 112 is received in the first region. Whenthe processor 140 receives the information from the sensor 130 that thesecond reflected light 122 has been received in columns 8 to 12 of row2, the processor 140 may determine that the second reflected light 122is received in the second region since the row which received the secondreflected light 122 is a low which is in a row lower than row 3 that isthe predetermined row.

The processor 140 may identify the first reflected light 112 included inthe first region as reflected light by the first light, and may identifythe second reflected light 122 included in the second region asreflected light by the second light. For example, as shown in FIG. 1A,as the first light 111 is reflected by a first object 10 and the secondlight 121 is reflected by a second object 20, if the first reflectedlight 112 and the second reflected light 122 are received in the sensor130 as illustrated in FIG. 3, the processor 140 may identify the firstreflected light 112 included in the first region as reflected light bythe first light, and may identify that the second reflected light 122included in the second region as reflected light by the second light.This is because, as described above, the first region is a region inwhich reflected light by the second light source 120 may not bereceived.

The first and second reflected light may be received in the secondregion. This will be described with reference to FIGS. 6A to 6C.

When the first reflected light 112 by the first light 111 is identified,the processor 140 may calculate a distance from the first light source110 and the first object 10 reflecting the first light 111 using thefirst algorithm. When the second reflected light 122 by the second light121 is identified by the processor 140, the processor 140 may calculatea distance from the second light source 120 to the second object 20reflecting the first light 121 using the second algorithm. The processor140 may calculate a first distance from the object that reflects thefirst light 111 and the electronic apparatus 100 and the second distancefrom the object that reflects the second light 121 and the electronicapparatus 100 using a different calculation scheme. Hereinafter, forconvenience, assuming an example where only the first reflected light112 is received at the sensor 130, and an example where only the secondreflected light 122 is received at the sensor 130, the method ofcalculating the distance between the electronic apparatus 100 and theobject will be described.

FIG. 4A is a diagram illustrating a case where reflected light isreceived by light of a first light source according to an embodiment ofthe disclosure.

FIG. 4B is a diagram illustrating a sensor receiving reflected light bylight of a first light source according to an embodiment of thedisclosure.

FIG. 4C is a diagram illustrating a method for calculating a distancebetween an electronic apparatus and an object based on the reflectedlight by light of the first light source according to an embodiment ofthe disclosure.

Referring to FIG. 4A, when the first light 111 irradiated by the firstlight source 110 is reflected by the first object 10, the sensor 130 mayreceive the first reflected light 112. In this example, when the firstreflected light 112 is received, the sensor 130 may sense the brightnessof the plurality of pixels included in the sensor 130. The sensor 130may sense pixels having a brightness greater than or equal to apredetermined brightness value among the plurality of pixels as pixelsreceiving the first reflected light 112, and transmit the position ofthe pixels received by the first reflected light 112 to the processor140. For example, as illustrated in FIG. 4B, the sensor 130 maytransmit, to the processor 140, information that the first reflectedlight 112 has been received at columns 8-12 of row 7.

Accordingly, the processor 140 may determine whether the position of thepixels that receive the first reflected light 112 is included in thefirst region or in the second region. In one example, when the processor140 receives information from the sensor 130 that the first reflectedlight 112 has been received, from the sensor 130, in the columns 8-12 ofrow 7, since the row in which the first reflected light 112 is receivedis 7 which is the upper row than row 3 that is a predetermined row, theprocessor 140 may determine that the first reflected light 112 isreceived in the first region.

The processor 140 may identify the first reflected light 112 included inthe first region as reflected light by the first light. For example, asillustrated in FIG. 1A, as the first light 111 is reflected by the firstobject 10, when the first reflected light 112 is received by the sensor130 as illustrated in FIG. 4B, the processor 140 may identify the firstreflected light 112 included in the first region as reflected light bythe first light. This is because as described above, the first region isa region in which reflected light by the second light source 120 may notbe received.

If the first reflected light 112 by the first light 111 is identified,the processor 140 may calculate a distance from the first light source110 to the first object 10 reflecting the first light 111 using thefirst algorithm.

The processor 140 may determine the first angle based on the location ofthe row of pixels that received the first reflected light 112. Theprocessor 140 may determine the first angle by multiplying the row valueof the pixels which received the first reflected light 112 by the angleper pixel on the column. For example, as illustrated in FIG. 4B, if thefirst reflected light 112 is received at the pixels of row 7, and theangle per pixel on the column is 8 degrees, the processor 140 maydetermine 56 degrees as the first angle.

The angle per pixel on the column may be determined based on the anglerange of the sensor 130 and the number of rows forming the plurality ofpixels included in the sensor 130. The angle per pixel on the column maybe the value of the angle of the sensor 130 divided by the number ofrows forming the plurality of pixels. For example, if the range of angleof view of the sensor 130 is 80 degrees (e.g., in the case of FIG. 4C,the angle of view of sensor 130 is the angle between imaginary line H1and imaginary line H2), and the plurality of pixels included in thesensor 130 are arranged in ten rows as shown in FIG. 4B, the angle perpixel on the column may be eight degrees. The range of view of angle ofthe sensor 130 may vary depending on the type of lens, or the like,included in the sensor 130.

The determined first angle may be an angle which is formed by a linewhich connects a point (z) at which the first light 111 is reflected bythe first object 10 and a virtual line hl according to the minimum angleamong the range of angle of view of the sensor 130.

The processor 140 may calculate a distance of the first light source 110and the first object 10 reflecting the first light 111 using thefollowing equation below.

y=r1×tan(a+b)

where u is the distance from the first light source 110 and the firstobject 10, and a is the first angle described above. Here, r1 is thedistance between the first light source 110 and the sensor 130, and b isthe installation angle of the sensor 130. The distance r1 between thefirst light source 110 and the sensor 130 and the installation angle bof the sensor 130 may be preset in the electronic apparatus 100. Thedistance r1 and the angle b may be set in the product manufacturingstage, but may be set according to user manipulation in a diversemanner. When the sensor 130 is installed such that a virtual lineaccording to the minimum angle among the range of angle of view of thesensor 130 is perpendicular to the ground, the angle b may be zero.

FIG. 5A is a diagram illustrating that reflected light is received bylight of a second light source according to an embodiment of thedisclosure.

FIG. 5B is a diagram illustrating a sensor receiving reflected light bylight of a second light source according to an embodiment of thedisclosure.

FIG. 5C is a diagram illustrating a method for calculating a distancebetween an electronic apparatus and an object based on reflected lightby light of the second light source according to an embodiment of thedisclosure.

Referring to FIG. 5A, when the second light 121 irradiated by the secondlight source 120 is reflected by the second object 20, the sensor 130may receive the second reflected light 122. In this example, when thesecond reflected light 122 is received, the sensor 130 may sense thebrightness of the plurality of pixels included in the sensor 130. Thesensor 130 may sense pixels having a brightness greater than or equal toa predetermined brightness value among the plurality of pixels as pixelsthat have received the second reflected light 122, and transmit theposition of the pixels which received the second reflected light 122 tothe processor 140.

Referring to FIG. 5B, the sensor 130 may transmit, to the processor 140,information that the second reflected light 122 has been received atcolumns 8-12 of row 7.

Accordingly, the processor 140 may determine whether the position of thepixels that received the second reflected light 122 is included in thefirst region or in the second region. For example, when the processor140 receives the information from the sensor 130 that the secondreflected light 122 has been received from the sensor 130, the processor140 may determine that the second reflected light 122 is received in thesecond region because the row received by the second reflected light 122is row 2 which is lower than the predetermined row 3.

The processor 140 may identify the second reflected light 122 includedin the second region as reflected light by the second light. Forexample, as the second light 121 is reflected by the second object 20 asshown in FIG. 1A, when the second reflected light 122 is received in thesecond reflected light 122 in the sensor 130 as shown in FIG. 5B, theprocessor 140 may identify the second reflected light 122 included inthe second region as the light reflected by the second light.

When the second reflected light 122 by the second light 121 isidentified, the processor 140 may calculate a distance from the secondlight source 120 to the second object 20 reflecting the second light 121using the second algorithm.

The processor 140 may determine a second angle based on the location ofthe row of pixels that received the second reflected light 122. Theprocessor 140 may determine a value obtained by multiplying the rowvalue of the pixels which received the second reflected light 122 by theangle per pixel on the column as the second angle. For example, as shownin FIG. 5B, if the second reflected light 122 is received at the pixelsof row 2, and the angle per pixel on the column is 8 degrees, theprocessor 140 may determine 16 degrees as the second angle.

Referring to FIG. 5C, the second angle determined by the second object20 may be an angle which is formed by the line connecting the point z2reflected by the second object 20 and the sensor 130, and the virtualline hl according to minimum angle among the range of angle of view ofthe sensor 130.

The processor 140 may calculate the distance to the second light source120 and the second object 20 reflecting the second light 121 using thefollowing equation as shown below:

y=r2×tan(a+b)×tan(c)/(tan(c)−tan(a+b))

This equation may be obtained by combination of equations 1 and 2.

y=(r2+r3)×tan(a+b)  Equation 1

y=r3×tan(c)  Equation 2

Here, y is the distance from the second light source 120 to the secondobject 20, and a is the second angle described above. r2 is the distancebetween the second light source 110 and the sensor 130, b is theinstallation angle of the sensor 130, and c is the illumination angle ofthe second light source 120, and r3 is the distance on the vertical axisbetween the second light source 120 and the point z2 where the secondlight 121 is reflected by the second object 20. The distance r2 betweenthe second light source 120 and the sensor 130, the installation angle bof the sensor 130, and the irradiation angle c of the second lightsource 120 may be preset in the electronic apparatus 100. The distancer1, angle b, and angle c may be set in the product manufacturingoperation, but may be variously set according to user manipulationwithout limitation. When the sensor 130 is installed such that thevirtual line according to the minimum angle among the range of angle ofview of the sensor 130 is installed in a direction perpendicular to theground, the angle b may be zero.

A method of calculating the distance between the electronic apparatus100 and the object is described with respect to the case where thereflected light is received in the first region of the sensor 130 andthe case where the reflected light is received in the second region ofthe sensor 130. The above technical idea may be applied even when aplurality of reflected light is received at the sensor 130 as shown inFIG. 3. The processor 140 may calculate a distance between theelectronic apparatus 100 and the object by applying a first algorithm tothe first reflected light 112 received in the first region, and maycalculate a distance between the electronic apparatus 100 and the objectby applying a second algorithm to the second reflected light 122received in the second region. As described above, the distance betweenthe electronic apparatus 100 and the object may be accurately calculatedeven when a plurality of reflected light is received at the sensor 130,by calculating the distance between the electronic apparatus 100 and theobject by dividing regions.

The first and second reflected lights may be received in the secondregion according to an embodiment. This will be described with referenceto FIGS. 6A to 6C.

FIG. 6A is a diagram illustrating a sensor receiving a plurality ofreflected lights in a second region according to an embodiment of thedisclosure.

FIG. 6B is a diagram illustrating that a plurality of objects arepositioned at a region capable of sensing an object by the second lightsource according to an embodiment of the disclosure.

FIG. 6C is a diagram illustrating that an object is positioned in aregion capable of sensing an object by the second light source accordingto an embodiment of the disclosure.

Referring to FIG. 6A, the sensor 130 may receive a first reflected light612 and a second reflected light 622 in the second region.

This may be a one of a case as illustrated in FIG. 6B that within thedistance d (i.e., within the range in which light irradiated from thesecond light source 120 can reach the ground), the first object 10 in asize where the light irradiated from the first light source 110 mayreach or the second object 20 in a size where the light irradiated fromthe second light source 120 can reach are located, or a case asillustrated in FIG. 6C that a third object 30 in a size where the lightirradiated from the first light source 110 and the light irradiated fromthe second light source 120 may reach within the distance d.

In the latter case, if a distance is calculated by applying a secondalgorithm to each of the first reflected light 612 and the secondreflected light 622 on the ground that the reflected light is receivedin the second region, the electronic apparatus may recognize that thefirst object 10 and the second object 20 exist at different positions.Thus, when a plurality of reflected light is received in the secondregion, it is necessary to distinguish whether a plurality of reflectedlight is reflected by one object or reflected by a plurality of objects.

The processor 140 may identify the reflected light by the first light611 and the reflected light by the second light 621, among the first andsecond reflected lights 612 and 622 received in the second region. Theprocessor 140 may identify the first reflected light 612 received at thepixels located in a relatively upper row among the plurality of pixelsthat received the first and second reflected light 612, 622 as reflectedlight by the first light 611 and may identify the second reflected light622 received at the pixels located in the relatively lower row asreflected light by the second light 621. This is because, by a geometricstructure in which the first light source 110 is arranged in thevertical direction of the second light source 120, the reflected lightby the first light 611 may be received in the pixels located in therelatively lower row, and the reflected light by the second light 621may be received in the pixels located in the relatively lower row.

The processor 140 may calculate the first distance by applying the firstalgorithm described above to the first reflected light 612, which isreflected by the first light 611. The processor 140 may determine thefirst angle based on the location of the row of pixels that received thefirst reflected light 612, and apply the first algorithm to the firstangle, the installation angle of the sensor 130, and the distance fromthe first light source 110 to the sensor 130 to calculate the firstdistance. For example, as illustrated in FIG. 6A, if the first reflectedlight 612 is received at the pixels of row 3, and the angle per pixel onthe column is 8 degrees, the processor 140 may determine 24 degrees asthe first angle.

The equation to calculate the first distance is as shown below:

y1=r1×tan(a+b)

Here, y1 is the first distance that is the distance from the first lightsource 110 to the object that reflects the first light, a is the firstangle described above, r1 is the distance between the first light source110 and the sensor 130, and b is the installation angle of the sensor130. The distance r1 between the first light source 110 and the sensor130 and the installation angle b of the sensor 130 may be preset in theelectronic apparatus 100 as described above.

The processor 140 may calculate the second distance by applying thesecond algorithm described above to the second reflected light 622,which is reflected by the second light 621. The processor 140 maydetermine the second angle based on the position of the row of pixelsthat received the second reflected light 622, apply a second algorithmto the second angle, the installation angle of the sensor 130, theillumination angle of the second light source 120, and the distance fromthe second light source 120 to the sensor 130 to calculate the seconddistance. For example, as illustrated in FIG. 6A, if the secondreflected light 622 is received at the pixels of row 2, and the angleper pixel on the column is 8 degrees, the processor 140 may determine 16degrees as the second angle.

The equation to calculate the second distance is as shown below:

y2=r2×tan(a+b)×tan(c)/(tan(c)−tan(a+b))

Here, y2 is the second distance that is the distance from the secondlight source 120 to the object that reflects the second light, and a isthe second angle described above. In addition, r2 is the distancebetween the second light source 110 and the sensor 130, and b is theinstallation angle of the sensor 130. c is the illumination angle of thesecond light source 120, and r3 is the distance on the vertical axisbetween the point at which the second light 121 is reflected by thesecond object 20 and the second light source 120. The distance r2between the second light source 120 and the sensor 130, the installationangle b of the sensor 130, and the irradiation angle c of the secondlight source 120 may be preset in the electronic apparatus 100.

If the columns of pixels receiving the first reflected light 612 and thecolumns of pixels receiving the second reflected light 622 match in atleast a part, the processor 140 may calculate the first and seconddistances described above. For example, as illustrated in FIG. 6A, asthe example where the columns of pixels that received the firstreflected light 612 are 8 to 12 and the columns of pixels that receivedthe second reflected light 622 are 8 to 12, if the columns of pixelsthat received the first reflected light 612 and the columns of pixelsthat received the second reflected light 622 match, the first and seconddistances described above may be calculated.

The case where there is no matching part among the columns that receivedthe reflect light may indicate that the first and second reflectedlights are received at different positions in the horizontal directionwith respect to the electronic apparatus 100, and each of the first andsecond reflected lights may be viewed as reflected by different objects.In this example, the processor 140 may calculate a distance between thefirst light source 110 and the first object and a distance between thesecond light source 120 and the second object by applying the secondalgorithm described above to each of the first and second reflectedlights. The processor 140 may calculate a first distance through thefirst algorithm and calculate a second distance through the secondalgorithm if the plurality of reflected light is received in the secondregion and the columns of the plurality of reflected light received inthe second region match at least in part. Accordingly, any unnecessaryoperation of the processor 140 may be prevented.

The processor 140 may identify whether the object reflecting the firstlight and the object reflecting the second light are the same object ordifferent objects based on a difference between the first and seconddistances calculated through the above-described method. If thedifference between the calculated first and second distances is lessthan or equal to a predetermined value, the processor 140 may identifythat the object reflecting the first light 611 and the object reflectingthe second light 621 are the same object 30. For example, if thedifference between the calculated first and second distances is thesame, as shown in FIG. 6C, the processor 140 may identify that theobject that reflects the first light 611 and the object that reflectsthe second light 621 are the same object 30. If the difference betweenthe calculated first and second distances exceeds a predetermined value,the processor 140 may identify that the object 10 reflecting the firstlight 611 and the object 20 reflecting the second light 621 aredifferent objects. For example, if it is determined that the differencebetween the calculated first and second distances is greater than orequal to one meter (1 m), the processor 140 may identify that the object10 reflecting the first light 611 and the object 20 reflecting thesecond light 621 are different objects, as shown in FIG. 6B. Here, 1 mis merely exemplary, and a predetermined value may be set in a diversemanner such as 50 cm, 2 m, or the like.

The processor 140 may then perform different operations, depending onwhether the object reflecting the first light and the object reflectingthe second light are the same object or different objects. In oneexample, if it is determined that the object reflecting the first lightand the object reflecting the second light are the same third object 30,the processor 140 may control the electronic apparatus 100 to drivewhile avoiding the third object 30 at the first distance (this is thesame as the second distance), and if it is determined that the objectreflecting the first light is the first object 10 and the objectreflecting the second light is the second object 20, the processor 140may control the electronic apparatus 100 to drive while avoiding thefirst object 10 at the first distance and drive while avoiding thesecond object 20 at the second distance.

It has been described above that the farther from the electronicapparatus 100, the reflected light is received at an upper portion ofthe sensor 130, and the nearer from the electronic apparatus 100, thereflected light may be received at an upper portion of the sensor 130.In this case, it is considered that a technical idea similar to that ofthe above-described technical idea may be applied. In this example, thereflected light received in a relatively upper row among reflected lightreceived in the second region may be identified as reflected light bythe second light, and the reflected light received in the relativelylower row may be identified as reflected light by the first light.

It is described that the reflected light received in the relativelyhigher row is identified as reflected light by the first light among thereflected light received in the second region based on the geometricstructure of the first light source 110 and the second light source 120,and that the reflected light received is received at a relatively lowerlow is identified as the reflected light by the second light, but thereflected light by the first light and the reflected light by the secondlight may be identified by various methods. This will be described laterwith reference to FIGS. 8A through 11.

FIG. 7 is a block diagram illustrating a sensor according to anembodiment of the disclosure.

Referring to FIG. 7, a sensor 700 may include a first light source 710,a second light source 720, an image sensor 730, and a processor 740. Thesensor 700 may be included in the electronic apparatus 100 describedabove. The image sensor 730 may include a plurality of pixels. Althoughnot shown in FIG. 7, the sensor 700 may further include a lens forreceiving reflected light.

The first light source 710 may perform a function same as the firstlight source 110. The first light source 710 may irradiate the firstlight in a front direction of the electronic apparatus 100.

The second light source 720 may perform the same function as the secondlight source 120. The second light source 720 may irradiate the secondlight in a direction different from the first light. For example, thesecond light source 720 may be disposed lower than the first lightsource 710, and may irradiate the second light from the front directionof the electronic apparatus 100 in the downward direction by 30 degrees,but is not necessarily limited thereto.

The first light source 710 and the second light source 720 may beimplemented as various light sources that may irradiate light such aslaser diode, line laser, or the like.

The image sensor 730 may be located in an upper portion of the firstlight source 710. The image sensor 730 may receive the reflected lightof the light irradiated toward the object. The image sensor 730 mayreceive the first reflected light when the first light irradiated by thefirst light source 710 is reflected by the object, and may receive thesecond reflected light when the second light irradiated by the secondlight source 720 is reflected by the object.

The plurality of pixels included in the image sensor 730 may be arrangedin a matrix form. A plurality of pixels may be arranged in the form ofM×M or M×N where M, N are integers. In one example, the image sensor 730may be composed of 200 pixels, and 200 pixels may be arranged in tenrows and 20 columns, but are not necessarily limited thereto.

The image sensor 730 may be divided into pixels of a first region andpixels in a second region. The first region is a region for calculatinga distance from the electronic apparatus 100 to an object located at afar distance from the electronic apparatus 100, and the second regionmay be a region for calculating a distance from the electronic apparatus100 to an object located at a near distance from the electronicapparatus 100.

The image sensor 730 may be divided into pixels of a first region andpixels in a second region based on pixels of a predetermined row. Forexample, if the predetermined row is row 3, the pixels included in row 3equal to or lower than the row 3 including the row 3 (i.e., row 1 to row3) may be divided into pixels of the first region, and the pixelsincluded in the row equal to or upper than row 3 (that is, rows 4 to row10) may be divided into pixels in the second region.

The predetermined row may be determined based on a location where thereflected light by the second light source 720 may be received at theimage sensor 730. For example, if the reflected light by the secondlight source 720 may be received only in pixels included in rows 1 to 3of the plurality of pixels 730, the predetermined row may be row 3. Theposition where the reflected light by the second light source 720 may bereceived in the image sensor 730 may be different according to theembodiment based on the illumination angle of the second light source720, the angle at which the sensor 130 is inclined in the grounddirection, and the like.

The processor 740 may control overall operations of the sensor 700. Theprocessor 740 may include, for example, and without limitation, one ormore of a central processing unit (CPU), an application processor (AP),a communication processor (CP), or the like. The processor 740 may beimplemented as at least one of a general processor, a digital signalprocessor, an application specific integrated circuit (ASIC), a systemon chip (SoC), a microcomputer (MICOM), or the like.

When the reflected light is received by the processor 740, the processor740 may sense a pixel that has received the reflected light among theplurality of pixels. The processor 740 may sense a pixel having abrightness greater than or equal to a predetermined brightness valueamong the plurality of pixels as a pixel that has received the reflectedlight. The predetermined brightness value may be variously set accordingto the brightness value of the light illuminated by the light source.

The processor 740 may receive information from the image sensor 730regarding the location of the pixels that received the first reflectedlight and the locations of the pixels that received the second reflectedlight from among the plurality of pixels included in the image sensor730. When the first and second reflected lights are received, the imagesensor 730 may sense the brightness of the plurality of pixels includedin the image sensor 730. The image sensor 730 may sense pixels having abrightness greater than or equal to a predetermined brightness valueamong the plurality of pixels as pixels receiving the first reflectedlight and pixels receiving the second reflected light, and transmitinformation regarding the position of the pixels receiving the firstreflected light and the position of the pixels receiving the secondreflected light to the processor 740.

The processor 740 may determine whether the position of the pixelsreceiving the first reflected light is included in the first region orthe second region. The processor 740 may determine whether the positionof the pixels receiving the second reflected light is included in thefirst region or the second region.

The processor 740 may identify the first reflected light included in thefirst region as the reflected light by the first light and identify thesecond reflected light included in the second region as the reflectedlight by the second light. As described above, the first region is theregion where the reflected light by the second light source 720 may notbe received.

When the first reflected light by the first light is identified by theprocessor 740, the processor 740 may calculate a distance between thefirst light source and the first object reflecting the first light usingthe first algorithm. When the second reflected light by the second lightis identified by the processor 740, the processor 740 may calculate adistance from the second light source to the second object reflectingthe first light using the second algorithm. The processor 740 maycalculate a first distance between the electronic apparatus 100 and theobject that reflects the first light and a second distance from theelectronic apparatus to the object that reflects the second light usinga different calculation scheme. The description of the first and secondalgorithms is described above, and will therefore be omitted.

When the first reflected light and the second reflected light arereceived in the second region of the image sensor 730, the processor 740may identify the reflected light by the first light and the reflectedlight by the second light among the first and second reflected lightbased on the position of the first pixels which received the firstreflected light and the position of the second pixels which received thesecond reflected light.

The processor 740 may identify the reflected light received in thepixels located at a relatively upper row, among the plurality of pixels,as the reflected light by the first light, and may identify thereflected light received in the pixels located at a relatively lower rowas the reflected light by the second light.

The processor 740 may calculate a first distance by applying the firstalgorithm described above to the first reflected light, which is areflected light by the first light. The processor 740 may determine thefirst angle based on the location of the row of pixels that received thefirst reflected light, apply the first algorithm to the first angle, theinstallation angle of the image sensor 730, and the distance from thefirst light source 710 to the image sensor 730 to calculate the firstdistance. For example, if the first reflected light is received at thepixels of row 3, and the angle per pixel on the column is 8 degrees, theprocessor 740 may determine 24 degrees as the first angle.

The equation to calculate the first distance is as shown below:

y1=r1×tan(a+b)

Here, y1 is the first distance from the first light source 710 and theobject that reflects the first light, and a is the first angle describedabove. In addition, r1 is the distance between the first light source710 and the image sensor 730, and b is the installation angle of theimage sensor 130. The distance r1 between the first light source 710 andthe image sensor 730 and the installation angle b of the image sensor730 may be preset in the sensor 700.

The processor 740 may calculate the second distance by applying thesecond algorithm described above to the second reflected light, which isreflected by the second light. The processor 740 may determine thesecond angle based on the position of the row of pixels that receivedthe second reflected light, apply a second algorithm to the secondangle, the installation angle of the image sensor 730, the illuminationangle of the second light source 720, and the distance from the secondlight source 720 to the image sensor 730 to calculate the seconddistance. As an example, if the second reflected light is received atthe pixels of row 2, and the angle per pixel on the column is 8 degrees,the processor 740 may determine 16 degrees as the second angle.

The equation to calculate the second distance is as shown below:

y2=r2×tan(a+b)×tan(c)/(tan(c)−tan(a+b))

y2 is the second distance that is the distance from the second lightsource 720 to the object that reflects the second light, a is the secondangle described above, r2 is the distance between the second lightsource 710 and the image sensor 730, and b is the installation angle ofthe image sensor 730. c is the illumination angle of the second lightsource 720, and r3 is the distance on the vertical axis between thepoint at which the second light is reflected by the second object andthe second light source 720. The distance r2 between the second lightsource 720 and the image sensor 730, the installation angle b of theimage sensor 730, and the irradiation angle c of the second light source720 may be preset in the sensor 700.

If the columns of pixels receiving the first reflected light and thecolumns of pixels receiving the second reflected light match in at leasta part, the processor 740 may calculate the first and second distancesdescribed above. For example, as in the case where the columns of pixelsthat received the first reflected light are 6 to 12 and the columns ofpixels that received the second reflected light are 8 to 12, if thecolumns of pixels that received the first reflected light 612 and thecolumns of pixels that received the second reflected light 622 match atleast in part, the first and second distances described above may becalculated.

If there is no matched part in the columns receiving the reflectedlight, the first and second reflected light are received at differentpositions in the horizontal direction with respect to the electronicapparatus 100, and each of the first and second reflected light may beviewed as reflected by different objects. In this example, the processor740 may apply the second algorithm described above to each of the firstand second reflected lights to calculate a distance between the firstlight source 710 and the first object and a distance from the secondlight source 720 to the second object. The processor 740 may calculate afirst distance through the first algorithm and calculate a seconddistance through the second algorithm if a plurality of reflected lightis received in the second region and the columns of the plurality ofreflected light received in the second region match at least in part.Accordingly, an unnecessary operation of the processor 740 may beprevented.

The processor 740 may identify whether the object reflecting the firstlight and the object reflecting the second light are the same object ordifferent objects based on a difference between the first and seconddistances calculated through the above-described method. The processor740 may identify that the object reflecting the first light and theobject reflecting the second light are the same object if the differencebetween the calculated first and second distances is less than or equalto a predetermined value. If the calculated difference between the firstand second distances exceeds a predetermined value, the processor 740may identify that the object reflecting the first light and the objectreflecting the second light are different objects. For example, if it isdetermined that the calculated difference between the first and seconddistances is greater than or equal to 1 m, the processor 740 mayidentify that the object reflecting the first light and the objectreflecting the second light may be identified as being differentobjects. 1 m is merely exemplary and a predetermined value may be set ina diverse manner, such as 50 cm, 2 m, or the like.

FIG. 8A is a diagram illustrating an embodiment of irradiating light ofdifferent patterns by a plurality of light sources according to anembodiment of the disclosure.

FIG. 8B is a diagram illustrating a sensor receiving a plurality oflights of different patterns according to an embodiment of thedisclosure.

Referring to FIG. 8A, the first light source 110 according to anembodiment may irradiate a first light 811 in a solid line pattern, andthe second light source 120 may irradiate a second light 821 in a dottedline pattern. For this purpose, a film to irradiate the dotted linepattern may be attached to the second light source 120.

Referring to FIG. 8B, the sensor 130 may receive a first reflected light812 in a solid line pattern and a second reflected light 822 in a dottedline pattern.

The processor 140 may identify, based on the pattern of reflected light,reflected light by the first light 811 and reflected light by the secondlight 821 from among the plurality of reflected light. The processor 140may identify the first reflected light 812 having the same pattern asthe pattern of the first light 811 as the reflected light by the firstlight 811, and identify the second reflected light 822 having the samepattern as the dotted line pattern of the second light 821 as thereflected light by the second light 812.

The processor 140 may apply a first algorithm to the first reflectedlight 812 to calculate a first distance, apply a second algorithm to thesecond reflected light 822 to calculate a second distance, and determinewhether the first and second reflected lights 812, 822 are lightreflected by the same object or light reflected by different objects, asdescribed above. Since the detailed description thereof has beendescribed above, a detailed description thereof will be omitted.

It has been described that the first light 811 is in the sold linepattern and the second light 821 is in the dotted line pattern, and thepattern of the first light 811 and the pattern of the second light 821may be various patterns that are different from each other.

FIG. 9A is a diagram illustrating an embodiment of irradiating light ofthickness by a plurality of light sources according to an embodiment ofthe disclosure.

FIG. 9B is a diagram illustrating a sensor receiving a plurality oflights having different thickness according to an embodiment of thedisclosure.

Referring to FIG. 9A, the first light source 110 according to anembodiment may irradiate first light 911 in the first thickness, and thesecond light source 120 may irradiate second light 921 in the secondthickness. The first thickness may be thicker than the second thickness,but it is not limited thereto and the second thickness may be thickerthan the first thickness. The size of the diode irradiating the lightincluded in the first light source 110 may be larger than the size ofthe diode that irradiates light included in the second light source 120.

The sensor 130 may receive the first reflected light 912 in the firstthickness and the second reflected light 922 in the second thickness asillustrated in FIG. 9B.

The processor 140 may identify, based on the thickness of the reflectedlight, the reflected light by the first light 911 and the reflectedlight by the second light 921 from among the plurality of reflectedlight. The processor 140 may identify the first reflected light 912having the same thickness as that of the first light 811 as reflectedlight by the first light 811, and identify the second reflected light922 having the same thickness as that of the second light 821 asreflected light by the second light 912.

The processor 140 may apply a first algorithm to the first reflectedlight 912 to calculate a first distance, apply a second algorithm to thesecond reflected light 922 to calculate a second distance, and determinewhether the first and second reflected lights 912, 922 are lightreflected by the same object or light reflected by different objects, asdescribed above. Since the detailed description thereof has beendescribed above, a detailed description thereof will be omitted.

Although the embodiment of identifying the reflected light by the firstlight 911 and the reflected light by the second light 921 is describedherein based on the thickness of the reflected light, the disclosure mayidentify the reflected light by the first light and the reflected lightby the second light based on the brightness of the reflected light. Asan example, the first light source 110 may irradiate a first light of afirst brightness, and the second light source 120 may irradiate a secondlight of a second brightness. The first brightness may be brighter thanthe second brightness, but it is not limited thereto and the secondbrightness may be brighter than the first brightness. For this purpose,a diode capable of irradiating light of a first brightness may beincluded in the first light source 110, and a diode capable ofirradiating light of a second brightness may be included in the secondlight source 120.

FIG. 10 is a diagram illustrating an embodiment of identifying reflectedlight by first light source and reflected light by second light sourceusing information on a thickness of reflected light according to anembodiment of the disclosure.

Referring to FIG. 10, the electronic apparatus 100 may store informationon the thickness of the reflected light by the first light sourcedivided by the distance and information on the thickness of thereflected light by the second light source. The information regardingthe thickness of the reflected light by the first light source isinformation matched with the thickness of the reflected light by thefirst light source received at the sensor 130, for each distance betweenthe electronic apparatus 100 and the object, and the information on thethickness of the reflected light by the second light source may beinformation matching the thickness of the reflected light by the secondlight source received at the sensor 130, for each distance between theelectronic apparatus 100 and the object.

The processor 140 may identify the reflected light by the first lightirradiated from the first light source 110 and the reflected light bythe second light irradiated from the second light source 120 among aplurality of reflected lights reflected to the sensor 112 based on theinformation on the thickness of the first and second reflected lights.

The processor 140 may apply the second algorithm described above to theplurality of reflected light included in the second region to determinea second distance that is the distance between the electronic apparatus100 and the object. The processor 140 may determine the thickness of thereflected light matched to the second distance based on information onthe thickness of the reflected light by the second light source as shownin FIG. 10. In one example, when the second distance is determined to be3 m, the processor 140 may determine 0.3 mm as the thickness of thereflected light matched to the second distance based on informationregarding the thickness of the reflected light by the second lightsource. If the thickness of the reflected light received by the sensor130 may match the thickness of the reflected light matched with thesecond distance, the processor 140 may determine that the reflectedlight is the reflected light by the second light source 120, and if thethickness does not match, the processor 140 may determine that thereflected light is reflected light by the first light source 110. Forexample, if it is determined that the thickness of the reflected lightdetermined on the basis of the information on the thickness of thereflected light by the second light source is 0.3 mm, but the thicknessof the actual reflected light received by the sensor 130 is determinedto be 0.2 mm, the processor 140 may determine that the reflected lightis by the first light source 110. In this example, the processor 140 mayapply the first algorithm to the reflected light again to calculate thedistance between the electronic apparatus 100 and the object. If thethickness of the actual reflected light received by the sensor 130 is0.3 mm and the thickness of the reflected light determined on the basisof the information on the thickness of the reflected light by the secondlight source is 0.3 mm, the processor 140 may determine that thereflected light is reflected by the second light source 110.

FIG. 11 is a diagram illustrating an embodiment of identifying reflectedlight by the first light source and reflected light by the second lightsource based on a cycle according to an embodiment of the disclosure.

Referring to FIG. 11, the first light source 110 and the second lightsource 120 may irradiate light at different cycles according to anembodiment. The first light source 110 may irradiate the first lightwith a period of T1. For example, when T1 is 1 msec, the first lightsource 110 may irradiate light in a period of 0 to 1 msec, and may notirradiate light in a period of 2 msec to 3 msec. The second light source120 may irradiate light at a different cycle than the first light source110. For example, when T1 is 1 msec, the cycle T2 of the second lightsource 120 may be 2 msec. In this example, the second light source 120may not irradiate light in a period of 0 to 1 msec, and may irradiatelight in the period of 2 msec to 3 msec.

Based on the cycle of the first light source 110 and the second lightsource 120, the processor 140 may identify whether the reflected lightis reflected by the first light source 110 or by the second light source120. The processor 140 may identify the reflected light received at thesensor 130 in the T1 cycle as reflected light by the first light source110, and may identify the reflected light received at the sensor 130 inthe T2 cycle as the reflected light by the second light source 120.

The processor 140 may calculate the first distance by applying the firstalgorithm to the reflected light by the first light source 110 andcalculate the second distance by applying the second algorithm to thereflected light by the second light source 120 to determine whether theplurality of reflected lights is lights reflected by the same object orlights reflected by different objects. This has been described in detailabove and will not be further described.

FIG. 12 is a flowchart illustrating a method for controlling anelectronic apparatus according to an embodiment of the disclosure.

Referring to FIG. 12, the electronic apparatus 100 may irradiate thefirst light through the first light source and may irradiate the secondlight in a direction different from the first light through the secondlight source in operation S1210. The first light source may be locatedat a row upper than or equal to the second light source.

When the first and second reflected lights are received by a sensor asthe first light and the second light are reflected by an object, theelectronic apparatus may calculate the first distance between theelectronic apparatus 100 and the object reflecting the first light andthe second distance between the electronic apparatus 100 and the objectreflecting the second light using different calculation methods inoperation S1220.

The sensor includes a plurality of pixels, and may be divided intopixels of a first region and pixels in a second region based on pixelsof a predetermined row. The electronic apparatus 100 may calculate afirst distance between the electronic apparatus 100 and the objectreflecting the first light and a second distance between the electronicapparatus 100 and the object reflecting the second light when the firstand second reflected light are received in the second region of thesensor and the columns of the first pixels receiving the first reflectedlight and the columns of the second pixels receiving the secondreflected light match at least in part.

The electronic apparatus 100 may identify reflected light received atpixels located in a relatively upper row of the plurality of pixelsincluded in the second region as reflected light by the first light, andidentify the reflected light received at the pixels located in therelatively lower row as reflected light by the second light.

The electronic apparatus 100 may determine the first angle based on theposition of the row of the first pixels receiving the first reflectedlight, calculate the first distance by applying the first algorithm tothe installation angle of the sensor and the distance from the firstlight source to the sensor, determine the second angle based on theposition of the row of the second pixels which received the secondreflected light, and calculate the second distance by applying thesecond algorithm to the second angle, the installation angle of thesensor, the irradiation angle of the second light source, and thedistance from the second light source to the sensor. Since a detaileddescription of the method of calculating the first and second distancesis described above, the description thereof will be omitted.

The electronic apparatus 100 may identify whether the object reflectingthe first light and the object reflecting the second light are the sameobject or different objects based on the calculated first and seconddistances in operation 51230.

If the difference between the calculated first and second distances isless than or equal to a predetermined value, the electronic apparatus100 may identify that the object reflecting the first light and theobject reflecting the second light are the same object, and if thedifference between the calculated first and second distances exceeds apredetermined value, the electronic apparatus 100 may identify that theobject reflecting the first light and the object reflecting the secondlight are different objects.

FIG. 13 is a flowchart illustrating a method for controlling a sensoraccording to an embodiment of the disclosure.

Referring to FIG. 13, the sensor 700 may irradiate the first lightthrough the first light source and may irradiate the second light in adirection different from the first light through the second light sourcein operation S1310. The first light source may be located at an upperportion of the second light source.

As the first and second lights are reflected by the object, if the firstand second reflected lights are received by the image sensor, the sensor700 may calculate the first distance between the electronic apparatus100 and the object reflecting the first light and the second distancebetween the electronic apparatus 100 and the object reflecting thesecond light by using a different calculation method in operation S1320.

The image sensor may include a plurality of pixels, and the plurality ofpixels may be divided into pixels of a first region and pixels in asecond region on the basis of pixels of a predetermined row. The sensor700 may calculate a first distance between the electronic apparatus 100and the object reflecting the first light and a second distance from theobject reflecting the second light when the first and second reflectedlight are received in the second region of the sensor and the columns ofthe first pixels receiving the first reflected light and the columns ofthe second pixels receiving the second reflected light match in at leasta part.

The sensor 700 may identify reflected light received at pixels locatedin a relatively upper row of the plurality of pixels included in thesecond region as reflected light by the first light, and identify thereflected light received at the pixels located in the relatively lowerrow as reflected light by the second light.

The sensor 700 may determine the first angle based on the position ofthe row of the first pixels receiving the first reflected light,calculate the first distance by applying the first algorithm to thefirst angle, installation angle of the image sensor and the distancefrom the first light source to the image sensor, determine the secondangle based on the position of the row of the second pixels receivingthe second reflected light, and calculate the second distance byapplying the second algorithm to the second angle, the installationangle of the image sensor, the irradiation angle of the second lightsource, and the distance from the second light source to the imagesensor. Since a detailed description of the method of calculating thefirst and second distances is described above, the description thereofwill be omitted.

FIG. 14 is a detailed block diagram illustrating an electronic apparatusaccording to an embodiment of the disclosure.

Referring to FIG. 14, the electronic apparatus 100 may include a firstlight source 110, a second light source 120, a sensor 130, a memory 150,an inputter 160, a display 170, a driver 180, a communicator 190, and aprocessor 140. The parts overlapped with the above description will beomitted or shortened.

The memory 150 may store operating systems (OS) for controlling theoverall operation of the components of the electronic apparatus 100 andinstructions or data associated with the components of the electronicapparatus 100.

The processor 140 may control multiple hardware or software componentsof the electronic apparatus 100 using various instructions or datastored in the memory 150, load instructions or data received from atleast one of the other components into a volatile memory, and store thevarious data in a non-volatile memory.

The memory 150 may store information about a first algorithm forcalculating the distance between the electronic apparatus 100 and theobject based on the reflected light by the first light source 110, andstore information about a second algorithm for calculating the distancebetween the electronic apparatus 100 and the object based on thereflected light by the second light source 120. The memory 150 may storeinformation about the thickness of the reflected light by the firstlight source 110 divided by the distance, and information on thethickness of the reflected light by the second light source 120.

The inputter 160 may receive a user input. The inputter 160 may includea button and a touch screen.

The display 170 may display a variety of screens. For example, thedisplay 170 may display information about the distance to objects andobjects around the electronic apparatus 100.

The display 170 may be implemented as various types of displays such as,for example, and without limitation, a liquid crystal display (LCD),plasma display panel (PDP), or the like. In the display 170, a backlightunit, a driving circuit which may be implemented as a format such as ana-si thin-film transistor (TFT), low temperature poly silicon (LTPS)TFT, organic TFT (OTFT), or the like, may be included as well. Thedisplay 170 may be combined with a touch sensor and implemented as atouch screen.

The driver 180 may move the electronic apparatus 100. The driver 180 mayinclude a driving unit such as a motor connected to one or more wheelsand capable of rotating the wheels. The driver 180 may perform a drivingoperation such as moving, stopping, changing a direction, or the like,of the electronic apparatus 100 according to a control signal of theprocessor 140. For example, if one object is located near the electronicapparatus 100, the driver 180 may be driven so that the electronicapparatus 100 drives by avoiding a corresponding object, and if aplurality of objects are located near the electronic apparatus 100, thedriver 180 may be driven so that the electronic apparatus 100 moves byavoiding a plurality of objects.

The communicator 190 is configured to communicate with an externaldevice. For example, the communicator 190 may communicate with variousexternal devices through a wireless communication method such asBluetooth (BT), Bluetooth low energy (BLE), wireless fidelity (Wi-Fi),Zigbee, or the like, or an infrared (IR) communication method. Thecommunicator 190 may be mounted on the processor 140, and may beincluded in the electronic apparatus 100 as a configuration separatefrom the processor 140.

In one embodiment, the electronic apparatus 100 may be implemented withthe exception of the configuration of some of the plurality ofconfigurations described above, and may further include a plurality ofadditional configurations other than those described above.

For example, the electronic apparatus 100 may further include a speaker.The speaker may include a component outputting various audio data onwhich various processes such as, for example, and without limitation,decoding, amplification, noise filtering, and the like, are performed byan audio processor (not illustrated). A speaker may output sound when adriving of the electronic apparatus 100 is started or when the drivingdirection is changed.

The electronic apparatus 100 may further include a microphone. Themicrophone may receive user voice. The user voice may be a user voice orthe like for task execution of the electronic apparatus 100.

According to various embodiments as described above, an electronicapparatus capable of identifying whether a plurality of reflected lightreceived in a sensor is light reflected by one object or light reflectedby a plurality of objects, and a control method thereof may be provided.

The methods according to various embodiments may be implemented as aformat of software or application installable to a related artelectronic apparatus.

The methods according to various embodiments may be implemented bysoftware upgrade of a related art electronic apparatus, or hardwareupgrade only.

The various embodiments described above may be implemented through anembedded server provided in the electronic apparatus or a server outsidethe electronic apparatus.

A non-transitory computer readable medium which stores a program forsequentially executing a method for controlling an electronic apparatusaccording to an embodiment may be provided.

The non-transitory computer readable medium refers to a medium that isreadable by an apparatus. To be specific, the aforementioned variousapplications or programs may be stored in the non-transitory computerreadable medium, for example, a compact disc (CD), a digital versatiledisc (DVD), a hard disk, a Blu-ray disc, a universal serial bus (USB), amemory card, a read only memory (ROM), and the like, and may beprovided.

While the disclosure has been shown and described with reference tovarious embodiments thereof, it will be understood by those of ordinaryskill in the art that various changes in form and details may be madetherein without departing from the spirit and scope of the disclosure asdefined by the appended claims and their equivalents.

What is claimed is:
 1. An electronic apparatus comprising: a sensor; afirst light source configured to irradiate a first light; a second lightsource configured to irradiate a second light in a direction differentfrom the first light; and a processor configured to: based on first andsecond reflected lights being received by the sensor as the first andsecond lights are reflected by an object, calculate a first distancebetween the electronic apparatus and an object reflecting the firstlight and a second distance between the electronic apparatus and anobject reflecting the second light using different calculation methods.2. The electronic apparatus of claim 1, wherein the processor is furtherconfigured to identify whether the object reflecting the first light andthe object reflecting the second light are same or different objectsbased on the calculated first and second distances.
 3. The electronicapparatus of claim 1, wherein the sensor comprises a plurality ofpixels, and wherein the processor is further configured to: identifyreflected light of the first light and reflected light of the secondlight among the first and the second reflected lights based on aposition of first pixels receiving the first reflected light and aposition of second pixels receiving the second reflected light among theplurality of pixels, and calculate the first distance and the seconddistance based on the identified reflected light.
 4. The electronicapparatus of claim 3, wherein the processor is further configured to:identify reflected light received at pixels located at a relativelyupper row among the plurality of pixels as reflected light of the firstlight, and identify reflected light received at pixels located at arelatively lower row on a column identical to the reflected light of thefirst light as the reflected light of the second light.
 5. Theelectronic apparatus of claim 3, wherein the plurality of pixels aredivided into pixels of a first region and pixels of a second regionbased on pixels of a predetermined row, and wherein the processor isfurther configured to, based on the first pixels and the second pixelsbeing included in the pixels of the second region, calculate the firstand second distances using the different calculation method.
 6. Theelectronic apparatus of claim 5, wherein the first light sourceirradiates the first light in a front direction of the electronicapparatus, wherein the second light source irradiates the second lightin a downward direction by a predetermined angle from the frontdirection, and wherein the second region comprises pixels disposed at arow lower than or equal to pixels in the predetermined row among theplurality of pixels.
 7. The electronic apparatus of claim 3, wherein theprocessor is further configured to: identify a first angle based on aposition of a row of the first pixels receiving the first reflectedlight and calculate the first distance by applying a first algorithm tothe first angle, an installation angle of the sensor, and a distancebetween the first light source and the sensor, and identify a secondangle based on a position of a row of the second pixels receiving thesecond reflected light and calculate the second distance by applying asecond algorithm to the second angle, an installation angle of thesensor, an irradiation angle of the second light source and a distancebetween the second light source and the sensor.
 8. The electronicapparatus of claim 2, wherein the processor is further configured to:based on a difference between the calculated first and second distancesbeing less than or equal to a predetermined value, identify that anobject reflecting the first light is same as an object reflecting thesecond light, and based on a difference between the calculated first andsecond distances being greater than the predetermined value, identifythat the object reflecting the first light is different from the objectreflecting the second light.
 9. A method for controlling an electronicapparatus, the method comprising: irradiating a first light through afirst light source and irradiating a second light in a directiondifferent from the first light through a second light source; and basedon first and second reflected lights being received by a sensor of theelectronic apparatus as the first and second lights are reflected by anobject, calculating a first distance between the electronic apparatusand an object reflecting the first light and a second distance betweenthe electronic apparatus and an object reflecting the second light usingdifferent calculation methods.
 10. The method of claim 9, furthercomprising: identifying whether the object reflecting the first lightand the object reflecting the second light are same or different objectsbased on the calculated first and second distances.
 11. The method ofclaim 10, wherein the sensor comprises a plurality of pixels, andwherein the calculating of the distance comprises: identifying reflectedlight of the first light and reflected light of the second light amongthe first and the second reflected lights based on a position of firstpixels receiving the first reflected light and a position of secondpixels receiving the second reflected light among the plurality ofpixels, and calculating the first distance and the second distance basedon the identified reflected light.
 12. The method of claim 11, whereinthe identifying of the reflected light comprises: identifying reflectedlight received at pixels located at a relatively upper row among theplurality of pixels as reflected light of the first light, andidentifying reflected light received at pixels located at a relativelylower row on a column identical to the reflected light of the firstlight as the reflected light of the second light.
 13. The method ofclaim 11, wherein the plurality of pixels are divided into pixels of afirst region and pixels of a second region based on pixels of apredetermined row, and wherein the calculating the distance comprises,based on the first pixels and the second pixels being included in thepixels of the second region, calculating the first and second distancesusing the different calculation method.
 14. The method of claim 13,wherein the first light source irradiates the first light in a frontdirection of the electronic apparatus, wherein the second light sourceirradiates the second light in a downward direction by a predeterminedangle from the front direction, and wherein the second region comprisespixels disposed at a row lower than or equal to pixels in thepredetermined row among the plurality of pixels.
 15. The method of claim11, wherein the calculating of the distance comprises: identifying afirst angle based on a position of a row of the first pixels receivingthe first reflected light and calculating the first distance by applyinga first algorithm to the first angle, an installation angle of thesensor, and a distance between the first light source and the sensor,and identifying a second angle based on a position of a row of thesecond pixels receiving the second reflected light and calculating thesecond distance by applying a second algorithm to the second angle, aninstallation angle of the sensor, an irradiation angle of the secondlight source and a distance between the second light source and thesensor.
 16. The method of claim 10, wherein the identifying of theobject comprises: based on a difference between the calculated first andsecond distances being less than or equal to a predetermined value,identifying that an object reflecting the first light is the same as anobject reflecting the second light, and based on a difference betweenthe calculated first and second distances being greater than thepredetermined value, identifying that the object reflecting the firstlight is different from the object reflecting the second light.
 17. Asensor comprising: a plurality of pixels; a first light sourceconfigured to irradiate a first light; a second light source configuredto irradiate a second light in a direction different from the firstlight; and a processor configured to: based on receiving the first andsecond reflected lights at the plurality of pixels as the first andsecond lights are reflected by an object, calculate a first distancebetween an electronic apparatus and an object reflecting the first lightand a second distance between the electronic apparatus and an objectreflecting the second light using different calculation methods.
 18. Thesensor of claim 17, wherein the processor is further configured to:identify reflected light by the first light and reflected light by thesecond light between the first and the second reflected lights based ona position of first pixels receiving the first reflected light and aposition of second pixels receiving the second reflected light among theplurality of pixels, and calculate the first distance and the seconddistance based on the identified reflected light.
 19. The sensor ofclaim 18, wherein the processor is further configured to: identifyreflected light received at pixels located at a relatively upper rowamong the plurality of pixels as reflected light by the first light, andidentify reflected light received at pixels located at a relativelylower row on a column identical to the reflected light by the firstlight as the reflected light by the second light.
 20. The sensor ofclaim 18, wherein the plurality of pixels are divided into pixels of afirst region and pixels of a second region based on pixels of apredetermined row, and wherein the processor is further configured to,based on the first pixels and the second pixels being included in thepixels of the second region, calculate the first and second distancesusing the different calculation method.